-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Summary
LaunchTube is being deprecated as a service and needs to be completely removed from the SDK. This is a breaking change for clients using the launchtube parameter in the send() method.
Related Issues
- API Issue: soroswap/api#189
Files Requiring Modification
| File | Changes Required |
|---|---|
src/types/send.ts |
Remove launchtube from SendRequest, remove 'launchtube' from submissionMethod |
src/soroswap-sdk.ts |
Remove launchtube parameter from send() method |
tests/soroswap-sdk.test.ts |
Update tests to remove launchtube parameter |
README.md |
Update documentation to remove launchtube references |
examples/backend-example.js |
Update examples to remove launchtube |
llms.txt |
Update LLM documentation |
CLAUDE.md |
Update Claude documentation |
Code Blocks to Remove/Update
1. src/types/send.ts - Remove launchtube from types
// UPDATE SendRequest interface - REMOVE launchtube field
export interface SendRequest {
xdr: string;
// REMOVE: launchtube?: boolean;
}
// UPDATE submissionMethod type FROM:
submissionMethod: 'soroban' | 'horizon' | 'launchtube';
// TO:
submissionMethod: 'soroban' | 'horizon';2. src/soroswap-sdk.ts - Update send method signature
// UPDATE send method (around line 137) FROM:
async send(xdr: string, launchtube: boolean = false, network?: SupportedNetworks): Promise<SendTransactionResponse> {
const params = { network: network || this.defaultNetwork };
const url = this.httpClient.buildUrlWithQuery('/send', params);
const sendData: SendRequest = { xdr, launchtube };
return this.httpClient.post<SendTransactionResponse>(url, sendData);
}
// TO:
async send(xdr: string, network?: SupportedNetworks): Promise<SendTransactionResponse> {
const params = { network: network || this.defaultNetwork };
const url = this.httpClient.buildUrlWithQuery('/send', params);
const sendData: SendRequest = { xdr };
return this.httpClient.post<SendTransactionResponse>(url, sendData);
}3. tests/soroswap-sdk.test.ts - Update tests
// UPDATE test (around line 286) - remove launchtube from expected request
it('should send transaction with default parameters', async () => {
const expectedRequest: SendRequest = {
xdr: 'SIGNED_XDR_123',
// REMOVE: launchtube: false
};
// ... update test call from send(xdr, false) to send(xdr)
});
// REMOVE entire test (around line 300)
it('should send transaction with launchtube enabled', async () => {
// DELETE THIS ENTIRE TEST
});
// UPDATE test (around line 314) - update to use new signature
it('should send transaction with specified network', async () => {
const expectedRequest: SendRequest = {
xdr: 'SIGNED_XDR_123',
// REMOVE: launchtube: false
};
// ... update test call from send(xdr, false, network) to send(xdr, network)
});4. README.md - Update documentation
// UPDATE line 55 FROM:
const result = await soroswapClient.send(signedXdr, false); // launchtube = false
// TO:
const result = await soroswapClient.send(signedXdr);
// UPDATE SoroswapClientConfig section (line 68) - REMOVE:
timeout?: number; // you might want to adjust this if using launchtube
// TO:
timeout?: number; // Request timeout in ms (defaults to 30000)
// UPDATE Send Transaction section (lines 147-152) FROM:
const result = await soroswapClient.send(
signedXdr, // The signed transaction XDR
false, // launchtube: boolean (default false)
SupportedNetworks.MAINNET // Optional network override
);
// TO:
const result = await soroswapClient.send(
signedXdr, // The signed transaction XDR
SupportedNetworks.MAINNET // Optional network override
);5. examples/backend-example.js - Update examples
// UPDATE line 84 FROM:
const sendResult = await sdk.send(signedXdr, false); // launchtube = false
// TO:
const sendResult = await sdk.send(signedXdr);
// UPDATE lines 173-175 FROM:
const { signedXdr, launchtube = false } = req.body;
const result = await sdk.send(signedXdr, launchtube);
// TO:
const { signedXdr } = req.body;
const result = await sdk.send(signedXdr);6. llms.txt - Update LLM documentation
// UPDATE lines 97-102 FROM:
- **Method**: `send(xdr: string, launchtube: boolean = false, network?: SupportedNetworks)`
- **Parameters**:
- `xdr`: Signed transaction XDR string
- `launchtube`: Use launchtube for submission (optional)
- `network`: Network override (optional)
// TO:
- **Method**: `send(xdr: string, network?: SupportedNetworks)`
- **Parameters**:
- `xdr`: Signed transaction XDR string
- `network`: Network override (optional)7. CLAUDE.md - Update Claude documentation
// UPDATE line 86 - REMOVE launchtube mention:
- `timeout` - Request timeout (default 30s, consider increasing for launchtube)
// TO:
- `timeout` - Request timeout (default 30s)Implementation Checklist
- Remove
launchtubefield fromSendRequestinterface - Remove
'launchtube'fromsubmissionMethodtype inSendTransactionResponse - Update
send()method signature to removelaunchtubeparameter - Update tests to reflect new signature
- Remove launchtube-specific test case
- Update README.md documentation
- Update examples/backend-example.js
- Update llms.txt
- Update CLAUDE.md
- Run tests to ensure everything passes
- Bump package version (breaking change)
- Update CHANGELOG with breaking change note
Breaking Change Migration
Before (deprecated):
// Using launchtube parameter
const result = await soroswapClient.send(signedXdr, true);
const result = await soroswapClient.send(signedXdr, false, SupportedNetworks.MAINNET);After:
// All transactions go directly to Stellar network
const result = await soroswapClient.send(signedXdr);
const result = await soroswapClient.send(signedXdr, SupportedNetworks.MAINNET);Version Bump
This is a breaking change that requires a major version bump due to:
- Removal of
launchtubeparameter fromsend()method - Change in method signature (parameter order changed)
- Removal of
'launchtube'fromsubmissionMethodresponse type
Notes
- The
SendTransactionResponsewill continue to work, just without'launchtube'as a possiblesubmissionMethodvalue - Clients should update their code to use the new
send(xdr, network?)signature - The API changes (soroswap/api#189) should be deployed before the SDK is published
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Todo